@extends('Home.layout.layout')
@section('title')
中药材{{$name}}---中药材天地网
@endsection
@section('css')
	<style>
		.pagination li {
				display:bloack;
				height: 30px;
				line-height: 30px;
				font-size: 16px;
				vertical-align:middle;
				margin: 10px;
				width: 30px;
				float: left;
				background-color: #fff;
		    }
		.pagination li span{
			height: 30px;
			line-height: 30px;
			font-size: 20px;
		}
		
		
	</style>
@endsection
@section('ptype')
{{$name}}
@endsection
@section('posts')
<!-- 新闻内容简介 -->
<ul>
@foreach($posts as $k=>$v)
	<li>
	   <h2><a href="{{url('/home/portalpost/scan',['id'=>$v->id])}}" target="_blank">{{$v->title}}</a></h2>
	    <div class="info">
	    	{{$v->summary}}
	    </div>
	    	
	    <p class="ft">
	        <span class="r">
	            药材：
	            	<!-- 链接到品种下的药材 -->
	                <a href="#" target="_blank">{{$v->mName}}</a>
	        </span>
	        <span class="g9">{{$v->ctime}}</span>
	    </p>
	</li>
@endforeach
</ul>
{!! $posts->render() !!} 
@endsection
@section('top')
<!-- top10排行榜 -->
<div class="subbox" id="topicRankingsRegion">
    <div class="topTen top-1">
    	<span style="font-size: 40px;background: #6F7FD4;color:#fff;">{{$name}}</span>
    	<hr>
    	<!-- <span style="font-size: 30px;background: #ccc;">Top</span> -->
    </div>
    <ul class="toplist">
    		<?php 
				$num=1;
			?>
    	@foreach($toppost as $k=>$v)
			
    		@if($num <= 3)
        	<li><strong>{{$num++}}</strong><a href="" title="{{$v->title}}">{{$v->title}}</a></li>
        	@else
        	<li><span>{{$num++}}</span><a href="" title="$v->title">{{$v->title}}</a></li>
        	
        	@endif
        @endforeach
    </ul>

</div>
@endsection
@section('new')
<!--最新新闻-->
<div class="subbox" id="newestTopicRegion">
    <div class="title">
        <span>最新资讯</span>
    </div>
    <ul class="txtlist">
		@foreach($newpost as $key=>$value)
        <li><a href="" title="">{{$value->title}}</a></li>
       	@endforeach 
    </ul>
</div>
@endsection